import { createStore, applyMiddleware } from 'redux';
// 可以派发promise或者payload为promise的action
import promise from 'redux-promise';
// 可以派发函数的action
import thunk from 'redux-thunk'
import reducers from './reducers';
import { routerMiddleware } from 'connected-react-router';
import history from './history';
// 应用路由中间件
export default applyMiddleware(routerMiddleware(history), thunk, promise)(createStore)(reducers);